using System.Configuration;

namespace SeguradoraIA.Framework.Configuration
{
    public class LoggerConfigurationCollection : ConfigurationElementCollection
    {
        public LoggerConfigurationCollection()
        {
            this.AddElementName = "logger";
        }

        protected override ConfigurationElement CreateNewElement()
        {
            return new LoggerConfigurationElement();
        }

        protected override object GetElementKey(ConfigurationElement element)
        {
            LoggerConfigurationElement elementKeys=(LoggerConfigurationElement) element;
            return elementKeys.TypeName + elementKeys.Arguments;
        }

        public LoggerConfigurationElement Get(int index)
        {
            return (LoggerConfigurationElement)BaseGet(index);
        }


        [ConfigurationProperty("publish")]
        public string Publish
        {
            get
            {
                return (string)this["publish"];
            }
            set
            {
                this["publish"] = value;
            }
        }

    }
}